﻿// ***********************************************************************
// Assembly         : SecurityLayer
// Author           : LJO+01 (Laurent Jordi)
// Created          : 06-05-2013
// Last Modified By : LJO+01 (Laurent Jordi)
// Last Modified On : 06-05-2013
// ***********************************************************************
// <copyright file="IMembershipService.cs" company="Copyright © Innovacall 2011">
//     Copyright (c) Copyright © Innovacall 2011. All rights reserved.
// </copyright>
// <summary></summary>
// ***********************************************************************
using System.Web.Security;

namespace InnovaApp.Layers.SecurityLayer.Models.AccountModels.MembershipServices
{
    /// <summary>
    /// Interface IMembershipService
    /// </summary>
    public interface IMembershipService
    {
        /// <summary>
        /// Gets the length of the min password.
        /// </summary>
        /// <value>The length of the min password.</value>
        int MinPasswordLength { get; }

        /// <summary>
        /// Validates the user.
        /// </summary>
        /// <param name="userName">Name of the user.</param>
        /// <param name="password">The password.</param>
        /// <returns><c>true</c> if XXXX, <c>false</c> otherwise</returns>
        bool ValidateUser(string userName, string password);
        /// <summary>
        /// Creates the user.
        /// </summary>
        /// <param name="userName">Name of the user.</param>
        /// <param name="password">The password.</param>
        /// <param name="email">The email.</param>
        /// <returns>MembershipCreateStatus.</returns>
        MembershipCreateStatus CreateUser(string userName, string password, string email);
        /// <summary>
        /// Changes the password.
        /// </summary>
        /// <param name="userName">Name of the user.</param>
        /// <param name="oldPassword">The old password.</param>
        /// <param name="newPassword">The new password.</param>
        /// <returns><c>true</c> if XXXX, <c>false</c> otherwise</returns>
        bool ChangePassword(string userName, string oldPassword, string newPassword);
    }
}
